﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace HYSoft.Web.Controls
{
    public partial class Search : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }
        protected void ImageButton1_Click(object sender, ImageClickEventArgs e)
        {
            string sreach = this.TextBox1.Text;
            if (sreach == null || sreach == "")
            {
                Response.Write("<script>alert('请输入需查询的内容！');</script>");
            }
            else
            {
                if ((string)Session["Usertype"] == "超级用户")
                {
                    Response.Write("<script>alert('请登录后再使用本平台！');top.location.href=\"index.html\";</script>");
                }
                else
                   Response.Redirect("listmode.aspx?sreach=" + Server.UrlEncode(sreach) + "");
            }
        }
    }
}